<include file="public@header"/>
</head>
<body class="gray-bg">
<div class="wrapper wrapper-content animated fadeInUp">
    <div class="row">
        <div class="col-sm-12">
            <div class="ibox float-e-margins">
                <div class="ibox-title">
                    <h5>角色列表</h5>
                    <div class="ibox-tools">
                        <a href="#" class="btn btn-primary btn-xs active">角色管理</a>
                        <a href="{:url('rbac/roleAdd')}" class="btn btn-primary btn-xs">添加角色</a>
                    </div>
                </div>
                <div class="ibox-content">
                    <table class="table table-hover">
                    <thead>
                    <tr>
                        <th width="40">
                            ID
                        </th>
                        <th align="left">
                            {:lang('ROLE_NAME')}
                        </th>
                        <th align="left">
                            {:lang('ROLE_DESCRIPTION')}
                        </th>
                        <th width="60" align="left">
                            {:lang('STATUS')}
                        </th>
                        <th width="160">
                            {:lang('ACTIONS')}
                        </th>
                    </tr>
                    </thead>
                    <tbody>
                    <foreach name="roles" item="vo">
                    <tr>
                        <td>
                            {$vo.id}
                        </td>
                        <td>
                            {$vo.name}
                        </td>
                        <td>
                            {$vo.remark}
                        </td>
                        <td>
                            <if condition="$vo['status'] eq 1">
                            <font color="red">√</font>
                            <else/>
                            <font color="red">╳</font>
                            </if>
                        </td>
                        <td>
                            <if condition="$vo['id'] eq 1">
                            <font color="#cccccc">{:lang('ROLE_SETTING')}</font><!-- <a href="javascript:openIframeDialog('{:url('rbac/member',array('id'=>$vo['id']))}','成员管理');">成员管理</a> | -->
                            <font color="#cccccc">{:lang('EDIT')}</font><font color="#cccccc">{:lang('DELETE')}</font>
                            <else/>
                            <a href="{:url('Rbac/authorize',array('id'=>$vo['id']))}">{:lang('ROLE_SETTING')}</a>
                            <!-- <a href="javascript:openIframeDialog('{:url('rbac/member',array('id'=>$vo['id']))}','成员管理');">成员管理</a>| -->
                            <a href="{:url('Rbac/roleedit',array('id'=>$vo['id']))}">{:lang('EDIT')}</a>
                            <a class="js-ajax-delete" href="{:url('Rbac/roledelete',array('id'=>$vo['id']))}">{:lang('DELETE')}</a>
                            </if>
                        </td>
                    </tr>
                    </foreach>
                    </tbody>
                    </table>
                </div>
            </div>
        </div>
    </div>
</div>
<script src="__STATIC__/js/admin.js"></script>
</body>
</html>